import React, { Component } from 'react'
import styled from 'styled-components'

const SpanBtn = styled.span`
   width: 160px;
   height: 80px;
   text-align:center;
   line-height: 80px;
   background:red;
   position:absolute;
   right: 50px;
`;
export default class HeaderCom extends Component {
  render() {
    return (
      <SpanBtn onClick={this.handleReset}>
        退出
      </SpanBtn>
    )
  }

  handleReset = () => {
    this.props.history.push('/login')
    sessionStorage.clear()
  }
}
